package demo1;

public class Dog extends Pet {

    public Dog(String name, int age, int love) {
        super(name, age, love);
    }

    public static void main(String[] args) {
        Pet dog=new Pet("小莫",18,96);
        dog.print();
        dog.age=1;
        System.out.println(dog.age);
        System.out.println(dog);
    }

}